
<% unless cart.line_items.empty? %>
<div class="cart_title">购物车</div>
<table>
	<%= render(cart.line_items) %>

  <tr class="total_line">
    <td colspan="2">总计</td>
    <td class="total_cell"><%= number_to_currency(cart.total_price) %></td>
  </tr>
  

</table>
<table>
  <tr>
	<td ><%= button_to '清空购物车', cart, :method => :delete, :remote => true, data: { confirm: "确定要删吗?" } %></td>
	<td>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</td>
	<td ><%= button_to '去结账', new_order_path, :method => :get, data: { confirm: "确定结算吗?" } %></td>
  </tr>
</table>

<% end %>